<?php
declare (strict_types = 1);

namespace app\admin\controller;

use addons\Builder\facade\Builder;
//该文件为自动生成，请按需修改
class UserPacket extends Base
{
    //主键，默认为id
    protected string $pk = 'id';

    //主模型
    protected string $model = '\app\common\model\UserPacket';

    //关联模型
    protected $hasOne = ['user'];
    public function index(): string
    {
       return Builder::Table()
           ->autoStructure($this->model, $this->pk, '')
           ->addExtraMap([['pay_status','=',1]])
           ->fetch();
    }
}
